import request from '@/utils/request'

// baseHoleScan
export const getList = (params) => {
  return request.get('/system/spec/list', { params })
}
export const deleteList = (params) => {
  return request.post('/system/spec/delete', {}, { params })
}

export function updateIsShow (isShow, spectrumId) {
  return request.post('system/spec/updateIsShow', {}, {
    params: {
      isShow,
      spectrumId
    }
  })
}
// foundationModel
export const getModelList = (params) => {
  return request.get('/system/foundationModel', { params })
}
export const addModel = (params) => {
  return request.post('/system/foundationModel', { ...params })
}
export const viewModel = (id) => {
  return request.get('/system/foundationModel/' + id)
}
export const editModel = (params) => {
  return request.put('/system/foundationModel/' + params.modelId, { ...params })
}
export const deleteModel = (id) => {
  return request.delete('/system/foundationModel/' + id)
}
export const uploadModel = (id) => {
  return request.get('/system/foundationModel/download/' + id, { responseType: 'blob' })
}
